package com.example.kotlin01

open class MyUser {

    open fun say(){
        println("say MyUser")
    }

}
class MyStudent :MyUser(){

    override fun say() {
        println("say MyStudent")
        super.say()
    }
    //内部类调用外部类的函数，以及调用外部类的超类函数
    inner class MyParent{
        fun say2(){
            say()
        }
        fun say3(){
            super@MyStudent.say()
        }
    }
}

fun main() {
    Namer.func1()
}

class Namer {
    companion object {
        fun func1(){
            println("aaaa")
        }
    }

}

